home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Belgian Amiga Club - ADF Collection
/
BS1 part 05.zip
/
BS1 part 5
/
ANC_UTULITYS_16.adf
/
arclist
/
asm1.arc
/
Avail.S
next >
Wrap
Text File
|
1988-09-21
|
607b
|
50 lines
;
; AvailMem Proggy.
;
beg:
moveq #0,d1
move.l 4.w,a6
jsr -216(a6)
move.l d0,d7
lea Workie,a0
lea 10(a0),a0
moveq #8,d5
loop:
divu #10,d0
move.l d0,d1
swap d0
clr.w d0
swap d0
swap d1
and.b #$f,d1
add.b #'0',d1
move.b d1,-(a0)
dbf d5,loop
moveq #0,d0
lea DosLib,a1
jsr -552(a6) ; OpenLibrary
move.l d0,a6
jsr -60(a6)
move.l d0,d6 ; Output handle
move.l d0,d1
move.l #Msg,d2
move.l #em-msg,d3
jsr -48(a6) ; Write it to screen
move.l a6,a1
move.l 4.w,a6
jsr -414(a6) ; CloseLibrary
moveq #0,d0
rts
Msg:dc "Available Mem:"
Workie:dc " Bytes",$0a
em:
even
doslib:dc "dos.library",0